<?php
	$menu = new Menu();
	$product = new Post();
	
?>
<?php
$where = " WHERE NewsTypeID in (
			SELECT MenuID
				FROM `menu`
				WHERE `ModuleID` LIKE 'product'
			)
			AND Status like '%[sanphamhot]%'
			ORDER BY `LastUpdate` DESC" ;
$datapro = $product->getTable($where);
if(count($datapro))
{
?>
<div class="ben-section">
    <div class="ben-section-title"><?php echo $product->ListStatus['sanphamhot']?></div>
    <div class="ben-section-content">
 	<?php foreach($datapro as $item) {?>
    <?php
    $obj = new Menu();
	$obj->loadByKeyLang($item['NewsTypeID'],$lang);
	
	?>
    	<p>
    		<a class="islink" href="<?php echo $obj->createLink($obj,$lang).$item['PostID'] ?>"><img src='<?php echo $img->resizePNG($item['ImagePath'],170,170)?>' class='ben-center' /></a>
            <div align="center"><a href="<?php echo $obj->createLink($obj,$lang).$item['PostID'] ?>"><h6><?php echo $item['Title']?></h6></a></div>
            <div align="center"><?php echo numberFormat($item['Price'])?> VNĐ</div>
            <div align="center">
                <a href="<?php echo $obj->createLink($obj,$lang).$item['PostID'] ?>">Chi tiết</a>
            </div>
        </p>
    <?php } ?>
    </div>
    <div class="clearer">&nbsp;</div>
</div>
<?php } ?>